Skip to content

Conversation

@FiberJW
Copy link
Member

@FiberJW FiberJW commented Mar 14, 2024

Why

To help a developer get configured for GitHub builds, it would be nice to let them use an EAS CLI command locally that sets up credentials for a build without actually executing it. In theory it would be awesome to be able to do this work from the browser/server, but as we know, some constraints prevent us from that.

How

I added a new command that largely inherits most of its behavior from ManageIos/ManageAndroid, but goes right to the SetUpBuildCredentials step for each platform, skipping printing out existing credentials and the 4+ step prompt flow that takes you to this action.

Test Plan

With neas as an alias pointed to my local build of EAS CLI,

neas credentials:configure-build should prompt you for both parameters and execute the build credentials setup for the selected platform.

neas credentials:configure-build --platform <android/ios> should prompt you for a build profile listed inside your eas.json and execute the build credentials setup for the selected platform.

neas credentials:configure-build --platform <android/ios> --profile PROFILE_NAME should immediately execute the build credentials setup for the selected platform.

@github-actions
Copy link

github-actions bot commented Mar 14, 2024

Size Change: -1.75 kB (0%)

Total Size: 51.4 MB

Filename Size Change
./packages/eas-cli/dist/eas-linux-x64.tar.gz 51.4 MB -1.75 kB (0%)

compressed-size-action

@codecov
Copy link

codecov bot commented Mar 14, 2024

Codecov Report

Attention: Patch coverage is 31.00775% with 89 lines in your changes are missing coverage. Please review.

Project coverage is 53.78%. Comparing base (e400515) to head (ebf0b34).

Files Patch % Lines
...rc/credentials/manager/SetUpIosBuildCredentials.ts 27.03% 25 Missing and 2 partials ⚠️
...redentials/manager/SetUpAndroidBuildCredentials.ts 26.93% 16 Missing and 3 partials ⚠️
...als/manager/CheckBuildProfileFlagAgainstEasJson.ts 14.29% 17 Missing and 1 partial ⚠️
...ials/manager/SetUpBuildCredentialsCommandAction.ts 25.00% 11 Missing and 1 partial ⚠️
...as-cli/src/commands/credentials/configure-build.ts 55.56% 8 Missing ⚠️
...kages/eas-cli/src/credentials/manager/ManageIos.ts 0.00% 3 Missing ⚠️
...s/eas-cli/src/credentials/manager/ManageAndroid.ts 60.00% 1 Missing and 1 partial ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #2282      +/-   ##
==========================================
- Coverage   53.94%   53.78%   -0.15%     
==========================================
  Files         520      525       +5     
  Lines       18993    19115     +122     
  Branches     4013     4037      +24     
==========================================
+ Hits        10243    10279      +36     
- Misses       8035     8114      +79     
- Partials      715      722       +7     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@FiberJW FiberJW force-pushed the fiberjw/eng-11573-create-an-eas-cli-command-that-does-the-credentials-setup branch from 3f1b4b2 to 94b217c Compare March 18, 2024 20:01
@FiberJW FiberJW changed the title Fiberjw/eng 11573 create an eas cli command that does the credentials setup [eas-cli] add a credentials:configure-build subcommand that prepares a project for EAS Build without executing the build from the CLI Mar 18, 2024
@FiberJW FiberJW force-pushed the fiberjw/eng-11573-create-an-eas-cli-command-that-does-the-credentials-setup branch from f1984db to ebf0b34 Compare March 22, 2024 20:11
@github-actions
Copy link

✅ Thank you for adding the changelog entry!

@FiberJW FiberJW requested a review from quinlanj March 22, 2024 20:11
@FiberJW FiberJW marked this pull request as ready for review March 22, 2024 20:11
Copy link
Member

@quinlanj quinlanj left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm, thx!

Copy link
Contributor

@szdziedzic szdziedzic left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

it's awesome, thanks! it looks good to me! I gave it a try locally and everything works well.

One follow-up thing we can do is to add credentials:configure-submit. It would be useful to also set up people using GH builds with --auto-submit this way, so we make sure that they have an ASC API key set on our servers. Or even make it a part of this command? What do you think about it?

@FiberJW
Copy link
Member Author

FiberJW commented Mar 28, 2024

Setting up auto-submit credentials is a good idea! I think making that a separate command is a good way to start and allow people to run what they want individually, but we can create a super credentials command that sets up everything for build, submit, notifications, and anything else later

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants